import Axios from "axios";
import *as constans from './constans'



const changeDetailData=(data)=>({
  type: constans.CHANGE_DETAIL_DATA,
  title: data.title,
  avatarURL: data.avatarURL,
  name:data.name,
  meta:data.meta,
  avatar:data.avatar,
  avaterImert:data.avaterImert
})
export const getList = ()=>{
    return(dispatch)=>{
        Axios.get('api/detail.json').then((ret)=>{
            const data = ret.data.data
            console.log(data);
            const action = changeDetailData(data)
        })
    }
}